/*
 *    Copyright (c) 2018-2025, lengleng All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * Neither the name of the pig4cloud.com developer nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 * Author: lengleng (wangiegie@gmail.com)
 */
package com.excesys.exsecs.om.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import java.time.LocalDateTime;

/**
 * 工单表
 *
 * @author weiyj
 * @date 2023-02-24 13:52:55
 */
@Data
@TableName("om_w_order")
@EqualsAndHashCode(callSuper = true)
@Schema(description = "工单表")
public class OmWOrder  extends Model<OmWOrder> {

	/**
	 * 主键
	 */
	@TableId(type = IdType.AUTO)
	@Schema(description = "主键")
	private Integer orId;

	/**
	 * 工单编号
	 */
	@Schema(description = "工单编号")
	private String orderNo;

	/**
	 * 工单名称
	 */
	@Schema(description = "工单名称")
	private String orderName;

	/**
	 * 事件编号
	 */
	@Schema(description = "事件编号")
	private String eventNo;

	/**
	 * 工单来源
	 */
	@Schema(description = "工单来源")
	private String orderFrom;

	/**
	 * 报修人ID
	 */
	@Schema(description = "报修人部门ID")
	private Long orderUserDeptId;

	/**
	 * 报修人ID
	 */
	@Schema(description = "报修人ID")
	private Long orderUserId;

	/**
	 * 报修人
	 */
	@Schema(description = "报修人")
	private String orderUserName;

	/**
	 * 报修人电话
	 */
	@Schema(description = "报修人电话")
	private String orderUserPhone;

	/**
	 * 报修类型;硬件更换、上门维修
	 */
	@Schema(description = "报修类型;硬件更换、上门维修")
	private String orderType;

	/**
	 * 设备区域
	 */
	@Schema(description = "设备区域")
	private String equipArea;

	/**
	 * 设备编号
	 */
	@Schema(description = "设备编号")
	private String equipNo;

	/**
	 * 设备名称
	 */
	@Schema(description = "设备名称")
	private String equipName;

	/**
	 * 报修说明
	 */
	@Schema(description = "报修说明")
	private String applyContent;

	/**
	 * 上传图片
	 */
	@Schema(description = "上传图片")
	private String applyFile;

	/**
	 * 报修时间
	 */
	@Schema(description = "报修时间")
	private LocalDateTime applyTime;

	/**
	 * 预约时间
	 */
	@Schema(description = "预约时间")
	@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	private LocalDateTime appointTime;

	/**
	 * 审批人ID
	 */
	@Schema(description = "审批人部门ID")
	private Long approveUserDeptId;

	/**
	 * 审批人
	 */
	@Schema(description = "审批人")
	private Long approveUserId;

	/**
	 * 审批人姓名
	 */
	@Schema(description = "审批人姓名")
	private String approveUserName;

	/**
	 * 审批人电话
	 */
	@Schema(description = "审批人电话")
	private String approveUserPhone;

	/**
	 * 故障等级
	 */
	@Schema(description = "故障等级")
	private String faultLevel;

	/**
	 * 工单状态
	 */
	@Schema(description = "工单状态")
	private String orderStatus;

	/**
	 * 处理人员部门ID
	 */
	@Schema(description = "处理人员部门ID")
	private Long handleUserDeptId;

	/**
	 * 处理人员
	 */
	@Schema(description = "处理人员")
	private Long handleUserId;

	/**
	 * 处理人员姓名
	 */
	@Schema(description = "处理人员姓名")
	private String handleUserName;

	/**
	 * 处理人员电话
	 */
	@Schema(description = "处理人员电话")
	private String handleUserPhone;

	/**
	 * 处理时间
	 */
	@Schema(description = "处理时间")
	private LocalDateTime handleTime;

	/**
	 * 处理备注
	 */
	@Schema(description = "处理备注")
	private String remark;

	/**
	 * 优先等级
	 */
	@Schema(description = "优先等级")
	private String priorityLevel;

	/**
	 * 满意程度
	 */
	@Schema(description = "满意程度")
	private String satisfaction;

	/**
	 * 评价内容
	 */
	@Schema(description = "评价内容")
	private String evaluation;

	/**
	 * 是否评价
	 */
	@Schema(description = "是否评价")
	private String evaluateFlag;

	/**
	 * 评价人
	 */
	@Schema(description = "评价人")
	private Long evaluateUserId;

	/**
	 * 区分维保工单
	 */
	@Schema(description = "区分维保工单")
	private String repairType;

	/**
	 * 是否指派
	 */
	@Schema(description = "是否指派")
	private String appointType;

//	/**
//	 * 房间号
//	 */
//	@Schema(description = "房间号")
//	private String roomNum;


//	/**
//	 * 公司名称
//	 */
//	@Schema(description = "公司名称")
//	private String companyName;

	/**
	 * 创建人
	 */
	@TableField(fill = FieldFill.INSERT)
	@Schema(description="创建人")
	private String createBy;

	/**
	 * 创建时间
	 */
	@TableField(fill = FieldFill.INSERT)
	@Schema(description="创建时间")
	private LocalDateTime createTime;

	/**
	 * 更新人
	 */
	@TableField(fill = FieldFill.INSERT_UPDATE)
	@Schema(description="更新人")
	private String updateBy;

	/**
	 * 更新时间
	 */
	@TableField(fill = FieldFill.INSERT_UPDATE)
	@Schema(description="更新时间")
	private LocalDateTime updateTime;


}
